﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;
using System.Data.SqlClient;

namespace DAL
{
    public class BuyerPrice
    {
        public static DataSet listWithAvgSellerPrice(int bpwid,string where,int pageIndex,int pageSize)
        {
            SqlParameter[] param = new SqlParameter[4];

            param[0] = new SqlParameter("@bpwid", SqlDbType.Int);
            param[0].Value = bpwid;

            param[1] = new SqlParameter("@where", SqlDbType.NVarChar, 4000);
            param[1].Value = where;

            param[2] = new SqlParameter("@pageIndex", SqlDbType.Int, 4);
            param[2].Value = pageIndex;

            param[3] = new SqlParameter("@pageSize", SqlDbType.Int, 4);
            param[3].Value = pageSize;

            return DbHelper.ExecuteReDataSet("p_Product_listWithAvgSellerPrice", param);
        }
    }
}
